import 'package:get/get.dart';
import 'package:library_base/route/i_router.dart';
import 'package:module_administrator/page/create_purchase_order/create_purchase_order_controller.dart';
import 'package:module_administrator/page/create_purchase_order/create_purchase_order_page.dart';
import 'package:module_administrator/page/create_purchase_order/goos_list/goods_list_controller.dart';
import 'package:module_administrator/page/create_purchase_order/goos_list/goods_list_page.dart';
import 'package:module_administrator/page/create_purchase_order/shipper/choose_shipper_controller.dart';
import 'package:module_administrator/page/create_purchase_order/shipper/choose_shipper_page.dart';
import 'package:module_administrator/page/create_purchase_order/single_head_entry/single_head_entry_controller.dart';
import 'package:module_administrator/page/create_purchase_order/single_head_entry/single_head_entry_page.dart';
import 'package:module_administrator/page/create_purchase_order/supplier/choose_supplier_controller.dart';
import 'package:module_administrator/page/create_purchase_order/supplier/choose_supplier_page.dart';
import 'package:module_administrator/page/create_purchase_order/warehouse/choose_warehouse_controller.dart';
import 'package:module_administrator/page/create_purchase_order/warehouse/choose_warehouse_page.dart';
import 'package:module_administrator/page/purchase_payment/purchase_payment_controller.dart';
import 'package:module_administrator/page/purchase_payment/purchase_payment_detail/purchase_payment_detail_controller.dart';
import 'package:module_administrator/page/purchase_payment/purchase_payment_detail/purchase_payment_detail_page.dart';
import 'package:module_administrator/page/purchase_payment/purchase_payment_page.dart';
import 'package:module_administrator/page/summary/summary_list_controller.dart';
import 'package:module_administrator/page/summary/summary_list_page.dart';
import 'package:module_administrator/page/tasks/buyer/choose_buyer_controller.dart';
import 'package:module_administrator/page/tasks/buyer/choose_buyer_page.dart';
import 'package:module_administrator/page/tasks/task_list_controller.dart';
import 'package:module_administrator/page/tasks/task_list_page.dart';
import 'package:module_administrator/page/workbanch_page.dart';
import 'package:library_base/route/routers.dart';
import 'package:library_base/route/middleware/login_middleware.dart';
import 'package:module_administrator/page/workbench_controller.dart';

class AdministratorRouter implements IRouter {
  @override
  List<GetPage> getPageBuilders() {
    return [
      GetPage(
          name: Routers.workbench,
          page: () => const WorkbenchPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => WorkbenchController());
          }),
          middlewares: [LoginMiddleware()]),
      GetPage(
          name: Routers.createPurchaseOrderPage,
          page: () => const CreatePurchaseOrderPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => CreatePurchaseOrderController());
          })),
      GetPage(
          name: Routers.chooseSupplierPage,
          page: () => const ChooseSupplierPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => ChooseSupplierController());
          })),
      GetPage(
          name: Routers.chooseWarehousePage,
          page: () => const ChooseWarehousePage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => ChooseWarehouseController());
          })),
      GetPage(
          name: Routers.chooseShipperPage,
          page: () => const ChooseShipperPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => ChooseShipperController());
          })),
      GetPage(
          name: Routers.addGoodsPage,
          page: () => const GoodsListPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => GoodsListController());
          })),
      GetPage(
          name: Routers.singleHeadEntryPage,
          page: () => const SingleHeadEntryPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => SingleHeadEntryController());
          })),
      GetPage(
          name: Routers.purchaseOrderTask,
          page: () => const TasksListPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => TasksListController());
          })),
      GetPage(
          name: Routers.chooseBuyerPage,
          page: () => const ChooseBuyerPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => ChooseBuyerController());
          })),
      GetPage(
          name: Routers.summaryListPage,
          page: () => const SummaryListPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => SummaryListController());
          })),
      GetPage(
          name: Routers.purchasePaymentPage,
          page: () => const PurchasePaymentPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => PurchasePaymentController());
          })),
      GetPage(
          name: Routers.purchasePaymentDetailPage,
          page: () => const PurchasePaymentDetailPage(),
          binding: BindingsBuilder(() {
            Get.lazyPut(() => PurchasePaymentDetailController());
          })),
    ];
  }
}
